package com.mapper.information;

import java.util.List;

import org.apache.ibatis.annotations.Param;

import com.po.DictionaryInfo;
import com.po.InformationInfo;
import com.po.SearchInfo;

public interface InformationMapper {
	public int addReczskColumn(int column);

	public int deleteReczskColumn(int column);

	public List<InformationInfo> getInformationList(InformationInfo informationInfo);
	
	public List<InformationInfo> getRecommendList();
	
	public int updateInformationKu(@Param("origin") String origin, @Param("destination") String destination);
	
	public int getInformationKuCount(@Param("origin") String origin);
	
	public InformationInfo getOneInformation(String info_id);

	public int deleteInformation(InformationInfo informationInfo);

	public int deleteInformations(String[] ids);
    
	public int getInformationCount(InformationInfo informationInfo);

	public List<InformationInfo> getSearchList(@Param("page") int offset, @Param("rows") int limit,
			@Param("category") String category, @Param("content") String content, @Param("library") String[] reczsk_id,
			@Param("tag_name") String tag_name, @Param("time") String time);

	public int getSearchCount(@Param("category") String category, @Param("content") String content,
			@Param("library") String[] reczsk_id, @Param("tag_name") String tag_name, @Param("time") String time);

	public List<InformationInfo> getADSearchList(@Param("page") int offset, @Param("rows") int limit,
			@Param("orlist") List<SearchInfo> orlist,@Param("andlist") List<SearchInfo> andlist, @Param("library") String[] reczsk_id,
			@Param("tag_name") String tag_name, @Param("time") String time);

	public int getADSearchCount(@Param("page") int offset, @Param("rows") int limit,
			@Param("orlist") List<SearchInfo> orlist,@Param("andlist") List<SearchInfo> andlist, @Param("library") String[] reczsk_id,
			@Param("tag_name") String tag_name, @Param("time") String time);
	
	public int addUploadinfo(InformationInfo informationinfo);
	
	public int addInformationList(List<InformationInfo> list);
	
	public int updateInformation(InformationInfo info);
	
	public int updateBrowser(String infoid);
	
	public int updateDownload(String infoid);
	
	public List<InformationInfo>  getInfoManage(@Param("infoname")String infoname,@Param("kudata") String kudata,@Param("infolevel")String infolevel,@Param("rows")int rows,@Param("page")int page);
	
	public int  getInfoManageCount(@Param("infoname")String infoname,@Param("kudata")String kudata,@Param("infolevel") String infolevel);
	
	public int  addDownload(@Param("userid")String userid,@Param("infoid")String infoid);

	public int  updateAccess(String date);
	
	public List<DictionaryInfo> getSearchYearList(@Param("category") String category, @Param("content") String content, @Param("library") String[] reczsk_id,
			@Param("tag_name") String tag_name, @Param("time") String time);
	
	public List<DictionaryInfo> getADSearchYearList(
			@Param("orlist") List<SearchInfo> orlist,@Param("andlist") List<SearchInfo> andlist, @Param("library") String[] reczsk_id,
			@Param("tag_name") String tag_name, @Param("time") String time);
   
	public int updateInfolevel(@Param("level")String level,@Param("infoid")String infoid);
	
	public int updateInfoslevel(@Param("level")String level,@Param("ids")String[] infoid);
	
	public int getInformation(InformationInfo info);
	
	public int updateInfoclass(@Param("kudata")String kudata,@Param("ids")String[] infoid);
	
	public List<InformationInfo>  getInfoExcel(@Param("infoname")String infoname,@Param("kudata") String kudata,@Param("infolevel")String infolevel);
	
	public List<InformationInfo> getInfokeywords(@Param("infoid")String infoid);
	
	public List<DictionaryInfo> getSearchTagList(@Param("category") String category, @Param("content") String content, @Param("library") String[] reczsk_id,
			@Param("tag_name") String tag_name, @Param("time") String time,@Param("dictionary_id")String dictionary_id);
	
	public List<DictionaryInfo> getADSearchTagList(
			@Param("orlist") List<SearchInfo> orlist,@Param("andlist") List<SearchInfo> andlist, @Param("library") String[] reczsk_id,
			@Param("tag_name") String tag_name, @Param("time") String time,@Param("dictionary_id")String dictionary_id);
}